cmake_minimum_required(VERSION 3.2)
project(aoi_test CXX C)

set(3RD ./3rd)
set(SRC ./src)

# 定义include目录
set(INC_DIR 
        ${3RD}/lua-5.4.3/src
)
include_directories(${INC_DIR})

# 定义lib目录
set(LIB_DIR ./libs)
set(LIB_FILE 
    liblua.a
)
link_directories(${LIB_DIR})

set(EXECUTABLE_OUTPUT_PATH ${CMAKE_SOURCE_DIR})

# 设置编译选项
add_compile_options(-ggdb -Wall -Wextra -pipe -O0 -fPIC)

# 定义通用静态库
set(LIB_COMM z dl rt)

file(GLOB_RECURSE SRC_AOI ${SRC}/*.c*)
#创建可执行文件
add_executable(aoi_test ${SRC_AOI})
target_link_libraries(aoi_test ${LIB_FILE} ${LIB_COMM})